ReplicateString (str, #copies)

Basic and Crystal syntax.

Arguments
Returns

Text String

Action

Replicates the string in str the number of times specified by #copies.

Typical uses

You can use this function to insert a line of characters any time they are needed. Some typical uses are:

Examples

The following examples are applicable to Crystal syntax:

If {file.SALES} < {file.QUOTA} Then

    ReplicateString("*",10)

Else

    ""

Prints the character * ten times as a flag.

{file.NAME}+ " " + ReplicateString("*", {file.SCORE})

Prints a simple bar graph showing test results. The formula prints an asterisk for each point in a test score (the value in the file.SCORE field).

The formula prints an asterisk for each point in a test score (the value in the {file.SCORE} field). For example, given the following data:

Name Score

Smith

23

Jones

17

Brown

21

Johnson

13

Reynolds

25

The formula will produce the following results:

Name @Score

Smith

***********************

Jones

******************

Brown

**********************

Johnson

***************

Reynolds

*****************************



Seagate Software IMG Holdings, Inc.
http://www.seagatesoftware.com
Support services:
http://support.seagatesoftware.com